/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package database;

import java.sql.Connection;
import java.sql.DriverManager;

/**
 *
 * @author jaime.castells
 */
public class Conexion {
    
   private Connection con;
    
    public Conexion(){

        try
        { 
            Class.forName("com.mysql.jdbc.Driver").newInstance();
            con = DriverManager.getConnection("jdbc:mysql://localhost/recommender", "root", "");
        }catch(Exception e){
            System.out.println("Error!");
        }
    }
    
    public Connection getConnection(){
        return con;
    }
}
   